luci-app-firewall: CBIProtocolSelect: properly handle unrecognized protos
authorJo-Philipp Wich <[email protected]>
Thu, 9 Dec 2021 15:24:31 +0000 (16:24 +0100)
committerJo-Philipp Wich <[email protected]>
Tue, 15 Feb 2022 23:52:03 +0000 (00:52 +0100)
commit161880046f0773c394c9a3e93171a1a595735c79
treed14a28dccee52f46ccad49117fc4faf3ebed6b74
parent2be076e5b1a02e37cae1bd47b3779f558d83f57c
luci-app-firewall: CBIProtocolSelect: properly handle unrecognized protos

Prevent incorrectly replacing unrecognized protocol numbers with -1.

Fixes: #5587
Signed-off-by: Jo-Philipp Wich <[email protected]>
(cherry picked from commit 43818163155d5ce49414a8e54f5746a85606ba03)
applications/luci-app-firewall/htdocs/luci-static/resources/tools/firewall.js